import React from 'react';
import {Modal} from 'antd';
import AdminList from "@/pages/sys/com/components/AdminList";

const AddAdminForm = (props) => {
  const {
    onCancel: handleAddAdminModalVisible,
    addAdminModalVisible,
    values,
    addTAdmin
  } = props;


  return (
    <Modal
      width={"fit-content"}
      bodyStyle={{
        padding: '32px 40px 48px',
      }}
      destroyOnClose
      visible={addAdminModalVisible}
      title={values.comName}
      footer={null}
      onCancel={() => handleAddAdminModalVisible()}
    >
      <AdminList userComId={values.id} addTAdmin={addTAdmin}/>
    </Modal>
  );
};

export default AddAdminForm;
